@keyframes :global(loading-spin) {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@mixin loading-spinner($iconPath) {
  text-indent: -9999px;
  &:after {
    :global {
      animation: loading-spin 1.5s linear;
      animation-iteration-count: infinite;
    }
    background: url($iconPath) no-repeat center;
    background-size: 30px;
    content: '';
    height: 30px;
    left: calc(50% - 15px);
    position: absolute;
    top: calc(50% - 15px);
    width: 30px;
  }
}
